package com.interesting.client.application;

import android.app.Activity;
import android.app.Application;

import com.interesting.base.lazylist.ImageLoader;
import com.interesting.base.utils.SQLiteUtil;
import com.interesting.client.bean.User;

public class TradeApplication extends Application {

	private static TradeApplication globalContext = null;
	private Activity activity = null;

	@Override
	public void onCreate() {
		super.onCreate();
		AppHolder.getInsatnce().imageLoader = new ImageLoader(this);
		AppHolder.getInsatnce().user = new User();
		AppHolder.getInsatnce().dbAdapter=  SQLiteUtil.getInstance(this);

		globalContext = this;
	}

	public static TradeApplication getInstance() {
		return globalContext;
	}

	public Activity getActivity() {
		return activity;
	}

	public void setActivity(Activity activity) {
		this.activity = activity;
	}
}
